package edu.kit.csl.cratylus.extraction;

import java.util.LinkedList;
import java.util.List;

import edu.kit.csl.cratylus.datatypes.Candidate;

/**
 * This splitter is named after the individualistic philosopher Jean-Paul
 * Sartre. It puts each candidate in a separate subset. Therefore, this 
 * splitter is the opposite of {@link MarxSplitter}.
 * 
 * @see MarxSplitter
 */
public class SartreSplitter implements Splitter {

	/* (non-Javadoc)
	 * @see edu.kit.csl.cratylus.extraction.Splitter#split(java.util.List)
	 */
	@Override
	public List<List<Candidate>> split(List<Candidate> candidates) {
		List<List<Candidate>> clusters = 
				new LinkedList<List<Candidate>>();
		for (Candidate candidate : candidates) {
			List<Candidate> cluster = new LinkedList<Candidate>();
			cluster.add(candidate);
			clusters.add(cluster);
		}
		return clusters;
	}
}
